import java.util.*;

/**
 * Created with IntelliJ IEDA.
 * Description:
 * User:86186
 * Date:2022-07-25
 * Time:9:53
 */
public class Test {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        HashSet<String> martic = new HashSet<>();
        while (scanner.hasNext()){
            martic.add(scanner.next());
        }
        int count = martic.size();
        System.out.println(count);
    }
}
